﻿@model CodeTier.BUL.SanPhamBUS
       
@{
    ViewBag.Title = "Index";
}
@using System.Drawing

<script type="text/javascript">

    function isNumberKey(evt) {

        var charCode = (evt.which) ? evt.which : event.keyCode
        if (charCode > 31 && (charCode < 48 || charCode > 57)) {
            return false;
        }
        return true;
    }
  </script>
 @using (Html.BeginForm("addToCart", "Cart", FormMethod.Get))
    {
     <div id="column1">
     <h1>Chi tiết sản phẩm</h1>
     <table style="float:left;margin-right:30px;margin-left:50px;color:#A28930;">
        <tr>
            <td> 
                <img src="data:image/jpg;base64,@(Convert.ToBase64String(Model.HinhAnh))" style="border-style: solid;
                    border-color: #643112;
                    border-width: 6px;
                    position: relative;" height="250px" width="350px"  alt="" />
            <td> 
               <div class="savebtn">
                      <div class="center">
                        <span>@Model.TenSP</span>
                        <i class="hori-line"></i>
                       </div>
                      <div class="gia">
                         @Model.DonGia <span>đ</span>
                       </div>
                       <div class="input"> 
               
                            <input type="hidden" id="txt_SL" name="txt_sl" value="1" style="width:50px;" onkeypress="return isNumberKey(event)" />
                            <input type="hidden" name="MaSP" value="@Model.MaSP" />
                            <input id="addToCart" class="button-link" type="submit" value="Mua" />
                        </div>
                </div> 
              </td>  
            </td>
        </tr>       
    </table> 
    <div class="center">
    <fieldset class="chitiet_sp"><legend style="color:Orange;" >Chi tiết sản phẩm</legend>
        <table width=100%>
            <tr>
            	<td width="16%" height="22" align="right">&nbsp;</td>
                <td width="31%" align="right" style="color:Orange;font-size:13px"><b>Giá :</b></td>
                <td width="53%" align="left" style="color: orange;font-size:13px"><b>@Model.DonGia</b></td>
            </tr>
            <tr>
            	<td width="16%" height="22" align="right">&nbsp;</td>
                <td width="31%" align="right" style="color: orange;font-size:13px"><b>Thông Tin Chi Tiết :</b></td>
                <td width="53%" align="left" style="color: orange;font-size:13px"><b>@Model.MoTa</b></td>
            </tr>
            
       </table>
    </fieldset>
    </div>
    </div>
    }
